package com.okaysoft.ofb

/**
 * 模板布局
 */
class FormworkComposition {

    Integer number //区块数值
    Category category //排列类别
    Integer  quantity //盘数量

    static belongsTo = [formworkDetail:FormworkDetail]  //模板详细编号
    static constraints = {
    }

    enum Category {
        HORIZONTAL_TOP2BOTTOMatTERMINAL_LEFT2RIGHT(0, '横排（盘列自上而下，端子自左而右）'),
        HORIZONTAL_TOP2BOTTOMatTERMINAL_RIGHT2LEFT(1, '横排（盘列自上而下，端子自右而左）'),
        HORIZONTAL_BOTTOM2TOPatTERMINAL_LEFT2RIGHT(2, '横排（盘列自下而上，端子自左而右）'),
        HORIZONTAL_BOTTOM2TOPatTERMINAL_RIGHT2LEFT(3, '横排（盘列自下而上，端子自右而左）'),
        VERTICAL_LEFT2RIGHTatTERMINAL_TOP2BOTTOM(4, '竖排（盘自左而右，端子自上而下）'),
        VERTICAL_LEFT2RIGHTatTERMINAL_BOTTOM2TOP(5, '竖排（盘自左而右，端子自下而上）'),
        VERTICAL_RIGHT2LEFTatTERMINAL_TOP2BOTTOM(6, '竖排（盘自右而左，端子自上而下）'),
        VERTICAL_RIGHT2LEFTatTERMINAL_BOTTOM2TOP(7, '竖排（盘自右而左，端子自下而上）')
        String label
        int id

        Category(int id, String label) {
            this.id = id
            this.label = label
        }
    }
}
